<%@include file="init.jsp" %>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <%@include file="head.jsp" %>
    </head>
    <body>
        <div id="page">
            <%@include file="menu.jsp" %>

            <div id="main-content">
                <h3>entradas compradas</h3>
                
                <table class="tablaGris">
                    <tr>
                        <th>Combate</th>
                        <th>Estadio</th>
                        <th>Fecha</th>
                    </tr>
                    <logic:notEmpty name="EntradasForm" property="listadoEntradas">
                        <logic:iterate name="EntradasForm" property="listadoEntradas" id="entrada">
                            <tr>
                                <td>
                                    <bean:write name="entrada" property="nombreBoxeador1"/> vs <bean:write name="entrada" property="nombreBoxeador2"/>
                                </td>
                                <td>
                                    <bean:write name="entrada" property="estadio"/>
                                </td>
                                <td>
                                    <bean:write name="entrada" property="fecha"/>
                                </td>
                            </tr>
                        </logic:iterate>
                    </logic:notEmpty>
                </table>     
                <hr/>
                <h3>entradas proximos combates</h3>
                <table id="tabla_combates" class="tablaGris">
                    <tr>
                        <th>Boxeador 1</th>
                        <th>Boxeador 2</th>
                        <th>Estadio</th>
                        <th>Fecha</th>
                        <th>Comprar</th>
                    </tr>
                    <logic:notEmpty name="EntradasForm" property="listadoCombates">
                        <logic:iterate name="EntradasForm" property="listadoCombates" id="combate">
                            <tr>
                                <td>
                                    <bean:write name="combate" property="nombreBoxeador1"/>
                                </td>
                                <td>
                                    <bean:write name="combate" property="nombreBoxeador2"/>
                                </td>
                                <td>
                                    <bean:write name="combate" property="estadio"/>
                                </td>
                                <td>
                                    <bean:write name="combate" property="fecha"/>
                                </td>
                                <td>
                                    <html:link action="VerEntrada.do?idCombate=${combate.idCombate}" >
                                        <html:img src="images/carrito.jpg" alt="comprar" style="margin-left:15px;width:30px;" />
                                    </html:link>
                                </td>
                            </tr>
                        </logic:iterate>
                    </logic:notEmpty>
                </table>     
            </div>
        </div>
    </body>
</html>
